import { defineStore } from 'pinia';
import { store } from '../index';

export const useDataStore = defineStore('data', {
  state: () => {
    return {
      dataSourceId: ''
    };
  },
  getters: {
    getDataSourceId(): string {
      return this.dataSourceId;
    }
  },
  actions: {
    setDataSourceId(v: string) {
      this.dataSourceId = v;
    }
  }
});

export const useDataStoreWithOut = () => {
  return useDataStore(store);
};
